package com.siashan.toolkit.image.painter;

import com.siashan.toolkit.image.element.AbstractElement;

import java.awt.*;

/**
 * 绘制接口
 *
 * @author  siashan
 * @since   1.0.8
 */
public interface IPainter {
    /**
     * 绘制
     *
     * @param g             2D图片
     * @param element       元素
     * @param canvasWidth   画布宽度
     * @throws Exception    异常
     */
    void draw(Graphics2D g, AbstractElement element, int canvasWidth) throws Exception;
}
